package cn.signalpha.modules.com.entity.enums;

import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * 类说明
 *
 * @author suguangjun
 */
@Getter
@AllArgsConstructor
public enum UserSignTypeEnum {

	NORMAL(1, "签到"),
	CONTINUOUS(2, "连续签到"),
	RETROACTIVE(3, "补签到"),
    ;

    final int type;
    final String name;

	public static UserSignTypeEnum instance(int type) {
		UserSignTypeEnum[] enums = values();
		for (UserSignTypeEnum userSignTypeEnum : enums) {
			if (userSignTypeEnum.getType() == type) {
				return userSignTypeEnum;
			}
		}
		return null;
	}

}
